The invention relates to a pilot controlled multiway valve comprising a principal valve which has a principal valve housing and an elongated valve spool arranged in a spool receiving space of the same, the valve spool having a control section for controlling a connection between valve ducts opening laterally into the spool receiving space and, at one end at least, a drive section serving for controlled fluid action, the component of the spool receiving space, containing the control section, being located in an integral principal housing part of the valve housing, and furthermore comprising at least one pilot valve included with the principal valve in a subassembly for the control of fluid action on at least one drive section of the valve spool, which possesses a head piece mounted on an assembly interface fitted with a pilot valve seat and having an electrically operated pilot control member.